home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1996 July: Mac OS SDK / Dev.CD Jul 96 SDK / Dev.CD Jul 96 SDK2.toast / Development Kits (Disc 2) / QuickDraw GX / Programming Stuff / Sample Code / Graphics Samples / Spectacle ƒ / Main.h < prev    next >
Encoding:
C/C++ Source or Header  |  1996-04-15  |  1.6 KB  |  79 lines  |  [TEXT/KAHL]

  1. /*
  2.  *    Main.h
  3.  *
  4.  *    Robert Dierkes,  November 11, 1993
  5.  *
  6.  *    Change History:
  7.  *
  8.  *       4/93    ???        New
  9.  *       4/96    bob        Removed unused macros (GetWindowKind & SetWindowKind).
  10.  *                    Added the copyright info.
  11.  *
  12.  *
  13.  *        © Apple Computer, Inc. 1990 - 1996  All rights reserved
  14.  *
  15.  */
  16.  
  17. #define        kGraphicsHeapSize    (400 * 1024L)
  18. #define        kCycleLength        (60*60)            /* Ticks */
  19.  
  20. /*----------------------*/
  21. /*    Menus & Windows        */
  22. /*----------------------*/
  23. enum
  24. {
  25.     menuBarRsrcID    = 128,
  26.     windowRsrcID    = 128,
  27.     appleMenuRsrcID    = 128,
  28.     fileMenuRsrcID,
  29.     animationMenuRsrcID,
  30.     objectMenuRsrcID,
  31.     windowMenuRsrcID,
  32.  
  33.     aboutRsrcID        = 128
  34. };
  35.  
  36. enum
  37. {
  38.     itemAbout        = 1,    /*    appleMenuRsrcID        */
  39.  
  40.     itemQuit        = 1,    /*    fileMenuRsrcID        */
  41.  
  42.     itemBegin        = 1,    /*    animationMenuRsrcID    */
  43.     itemEnd,
  44.     itemStep,
  45.  
  46.     itemSquare        = 1,    /*    objectMenuRsrcID    */
  47.     itemOval,
  48.     itemDash1,
  49.     itemDither,
  50.     itemHalftone,
  51.  
  52.     itemShowFrame    = 1,    /*    windowMenuRsrcID    */
  53.     itemDash2,
  54.     itemMinimumPanes,
  55.     itemDash3 = itemMinimumPanes + kMaximumPanesPerSide,
  56.     itemCycle
  57. };
  58.  
  59.  
  60. #define        kHiliteAllMenus        (short) 0
  61. #define        kWindowOnTop        ((WindowPtr) -1)
  62. #define        kWindowTitleHeight    (short) 20
  63.  
  64.  
  65. Boolean    InitApp (void);
  66. void ExitApp (void);
  67. void InitializeMenus (void);
  68. WindowPtr InitializeWindow (void);
  69. void DoContentClick (EventRecord *pEvent, WindowPtr theWindow);
  70. void DoMenuCommand (long menuResult);
  71. void DoGrowBox (EventRecord *pEvent, WindowPtr theWindow);
  72. void DoZoomBox (EventRecord *pEvent, WindowPtr theWindow, short windowPart);
  73. void DoNullEvent (EventRecord *pEvent);
  74. void DoMouseDown (EventRecord *pEvent);
  75. void DoKeyStroke (EventRecord *pEvent);
  76. void DoUpdate (EventRecord *pEvent);
  77. void DoActivate (EventRecord *pEvent);
  78. void DoEvent (void);
  79.